# -*- coding: utf-8 -*-
from datetime import timedelta
from utils.operators.spark_submit import SparkSubmitOperator
from jms.ods.tms import jms_ods__yl_tmsnew_tms_vehicle_line
from jms.time_sensor.time_after_08_00 import time_after_08_00

hbase__yl_tmsnew_tms_vehicle_line_2hbase = SparkSubmitOperator(
    task_id='hbase__yl_tmsnew_tms_vehicle_line_2hbase',
    pool_slots=2,
    email=['shenjiaming@jtexpress.com'],
    name='hbase__yl_tmsnew_tms_vehicle_line_2hbase',
    driver_memory='4G',
    executor_memory='8G',
    executor_cores=4,
    num_executors=2,
    java_class='com.yunlu.bigdata.jobs.export.Hive2HbaseVehicleLine',
    application='hdfs:///scheduler/jms/spark/lch/vehicle_line/jobs-1.0-SNAPSHOT.jar',
    application_args=['{{ execution_date | cst_ds }}'],
    execution_timeout=timedelta(hours=2),
)
hbase__yl_tmsnew_tms_vehicle_line_2hbase << [jms_ods__yl_tmsnew_tms_vehicle_line,time_after_08_00]
